From b71134fc77630c20b2b8a0d19a855a7b665b9403 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Sun, 30 Jan 2011 02:46:59 -0500 Subject: [PATCH] Drop unused theme-bits --- configure.ac | 1 - gtk/Makefile.am | 10 +- gtk/theme-bits/Makefile.am | 15 -- gtk/theme-bits/README | 29 ---- gtk/theme-bits/check-13-inconsistent.png | Bin 197 -> 0 bytes gtk/theme-bits/check-13.png | Bin 267 -> 0 bytes gtk/theme-bits/decompose-bits.c | 177 ----------------------- gtk/theme-bits/radio-13-inconsistent.png | Bin 335 -> 0 bytes gtk/theme-bits/radio-13.png | Bin 317 -> 0 bytes 9 files changed, 2 insertions(+), 230 deletions(-) delete mode 100644 gtk/theme-bits/Makefile.am delete mode 100644 gtk/theme-bits/README delete mode 100644 gtk/theme-bits/check-13-inconsistent.png delete mode 100644 gtk/theme-bits/check-13.png delete mode 100644 gtk/theme-bits/decompose-bits.c delete mode 100644 gtk/theme-bits/radio-13-inconsistent.png delete mode 100644 gtk/theme-bits/radio-13.png diff --git a/configure.ac b/configure.ac index 57a3519345..0e9849d7aa 100644 --- a/configure.ac +++ b/configure.ac @@ -1674,7 +1674,6 @@ gtk/Makefile gtk/makefile.msc gtk/gtkversion.h gtk/gtk-win32.rc -gtk/theme-bits/Makefile gtk/tests/Makefile modules/Makefile modules/other/Makefile diff --git a/gtk/Makefile.am b/gtk/Makefile.am index 508c4aad84..31dc7890e8 100644 --- a/gtk/Makefile.am +++ b/gtk/Makefile.am @@ -16,8 +16,8 @@ else GTK_PRINT_PREVIEW_COMMAND="evince --unlink-tempfile --preview --print-settings %s %f" endif -SUBDIRS = theme-bits . tests -DIST_SUBDIRS = theme-bits tests +SUBDIRS = tests +DIST_SUBDIRS = tests if HAVE_PAPI_CUPS GTK_PRINT_BACKENDS=file,papi,cups @@ -1348,12 +1348,6 @@ gtkbuiltincache.h: @REBUILD@ stamp-icons EXTRA_DIST += \ $(STOCK_ICONS) \ $(GENERATED_ICONS) \ - line-arrow.xbm \ - line-wrap.xbm \ - tree_plus.xbm \ - tree_minus.xbm \ - tree_minus.xpm \ - tree_plus.xpm \ gtk.def \ gtk-win32.rc \ gtk-win32.rc.in \ diff --git a/gtk/theme-bits/Makefile.am b/gtk/theme-bits/Makefile.am deleted file mode 100644 index 0c6d3b2d74..0000000000 --- a/gtk/theme-bits/Makefile.am +++ /dev/null @@ -1,15 +0,0 @@ -include $(top_srcdir)/Makefile.decl - -INCLUDES = \ - -I$(top_srcdir) \ - -I$(top_builddir) \ - $(BASE_DEPENDENCIES_CFLAGS) - -noinst_PROGRAMS = decompose-bits - -decompose_bits_SOURCES = decompose-bits.c -decompose_bits_LDADD = $(BASE_DEPENDENCIES_LIBS) - -EXTRA_DIST += check-13.png check-13-inconsistent.png radio-13.png radio-13-inconsistent.png - --include $(top_srcdir)/git.mk diff --git a/gtk/theme-bits/README b/gtk/theme-bits/README deleted file mode 100644 index bbb3758c88..0000000000 --- a/gtk/theme-bits/README +++ /dev/null @@ -1,29 +0,0 @@ -This directory contains bits and pieces used in the default theme. -Right now, it contains a tool for extracting individual part -bitmaps from a composed image, and source images for the default -check and radio buttons. - -The decompose-bits tools takes an image where the first line contains -the colors for each part, and the rest of the image is the actual -image. - -The colors on the first line are: - - pixel 0: black - pixel 1: dark - pixel 2: mid - pixel 3: light - pixel 4: text - pixel 5: text_aa - pixel 6: base - -The generated XBM bits for the base part include the bits for text and -text_aa as well; this is so that the result can be drawn either -with or without the text/text_aa indicator. - -Make sure that any PNG images added to this directory are added with -'cvs add -kb'. - -Owen Taylor -9 February 2002 - diff --git a/gtk/theme-bits/check-13-inconsistent.png b/gtk/theme-bits/check-13-inconsistent.png deleted file mode 100644 index 3b27dc5a1a5f9fba0c603847a1cd8cfb33d7ffca..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 197 zcmeAS@N?(olHy`uVBq!ia0vp@K+MO%1SG3v8C!uAXMsm#F#`j)00=X#Ro+_)6l5>) z^mS#w#3U>tu9X-0s}d-b;_2cTQZXkvB_UykQEAuGl}jhC4CGNxE@N*_{dw`h7eBU; z0~V>TMA(uT3}5~G|NlHwvh2~NFYaXWv9YnKEz()K&q~ZfyX~S>a24m7yGv$oXW2g8 p)1cp_TCvg7;qL$c|2b!|Gdzlr;qo(hz6fX^gQu&X%Q~loCID^yKvDnz diff --git a/gtk/theme-bits/check-13.png b/gtk/theme-bits/check-13.png deleted file mode 100644 index 50622eff597dec3c3f3df09e3d573c4ceeb58ccc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 267 zcmeAS@N?(olHy`uVBq!ia0vp@K+MO%1SG3v8C!uAOS+@4BLl<6e(pbstUx|zfk$L9 z0|U1Z2s2)~TlWVj$X?><>&kwKiBpJQ(=X}AWuVY3PZ!6KiaEU#4EYW#@VM^RZkwkb z#CF7R*QW9Z3?~H>+NBFbrz{Lw|AcRuXE5U_`8WC>Q|f&flDev{UABo-dcJV_rwX;=+BGs@JfopWj)$;F$fajI-*;Wjq)Yo*A+{U|yqY;>@u~{{YaH44$rj JF6*2UngEM6UBdtX diff --git a/gtk/theme-bits/decompose-bits.c b/gtk/theme-bits/decompose-bits.c deleted file mode 100644 index 99d84a40f1..0000000000 --- a/gtk/theme-bits/decompose-bits.c +++ /dev/null @@ -1,177 +0,0 @@ -/* GTK - The GIMP Toolkit - * Copyright (C) 2002, Owen Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "config.h" -#include -#include -#include -#include - -#define BYTES_PER_OUTPUT_LINE 15 - -static gint -output_byte (guchar byte, - gint online) -{ - if (online == BYTES_PER_OUTPUT_LINE) - { - g_printf (",\n "); - online = 0; - } - else if (online) - { - g_printf (","); - } - - g_printf ("0x%02x", byte); - return online + 1; -} - -static void -do_part (GdkPixbuf *pixbuf, - gint part1_index, - gint part2_index, - gint part3_index, - const char *base_name, - const char *part_name) -{ - const guchar *pixels = gdk_pixbuf_get_pixels (pixbuf); - const guchar *color1; - const guchar *color2; - const guchar *color3; - gint rowstride = gdk_pixbuf_get_rowstride (pixbuf); - gint n_channels = gdk_pixbuf_get_n_channels (pixbuf); - gint width = gdk_pixbuf_get_width (pixbuf); - gint height = gdk_pixbuf_get_height (pixbuf); - gint online = 0; - - color1 = pixels + part1_index * n_channels; - color2 = pixels + part2_index * n_channels; - color3 = pixels + part3_index * n_channels; - pixels += rowstride; - - g_printf ("static const guchar %s_%s_bits[] = {\n", base_name, part_name); - g_printf (" "); - - while (height--) - { - guchar bit = 1; - guchar byte = 0; - const guchar *p = pixels; - gint n = width; - - while (n--) - { - if ((part1_index >= 0 && memcmp (p, color1, n_channels) == 0) || - (part2_index >= 0 && memcmp (p, color2, n_channels) == 0) || - (part3_index >= 0 && memcmp (p, color3, n_channels) == 0)) - byte |= bit; - - if (bit == 0x80) - { - online = output_byte (byte, online); - byte = 0; - bit = 1; - } - else - bit <<= 1; - - p += n_channels; - } - - if (width & 7) /* a leftover partial byte */ - online = output_byte (byte, online); - - pixels += rowstride; - } - - g_printf ("};\n"); -} - -typedef enum { - PART_BLACK, - PART_DARK, - PART_MID, - PART_LIGHT, - PART_TEXT, - PART_TEXT_AA, - PART_BASE, - PART_LAST -} Part; - -static const char *part_names[PART_LAST] = { - "black", - "dark", - "mid", - "light", - "text", - "aa", - "base", -}; - -int main (int argc, char **argv) -{ - gchar *progname = g_path_get_basename (argv[0]); - GdkPixbuf *pixbuf; - GError *error = NULL; - gint i; - - if (argc != 3) - { - g_fprintf (stderr, "%s: Usage: %s FILE BASE\n", progname, progname); - exit (1); - } - - g_type_init (); - - pixbuf = gdk_pixbuf_new_from_file (argv[1], &error); - if (!pixbuf) - { - g_fprintf (stderr, "%s: cannot open file '%s': %s\n", progname, argv[1], error->message); - exit (1); - } - - if (gdk_pixbuf_get_width (pixbuf) < PART_LAST) - { - g_fprintf (stderr, "%s: source image must be at least %d pixels wide\n", progname, PART_LAST); - exit (1); - } - - if (gdk_pixbuf_get_height (pixbuf) < 1) - { - g_fprintf (stderr, "%s: source image must be at least 1 pixel height\n", progname); - exit (1); - } - - g_printf ("/*\n * Extracted from %s, width=%d, height=%d\n */\n", argv[1], - gdk_pixbuf_get_width (pixbuf), gdk_pixbuf_get_height (pixbuf) - 1); - - for (i = 0; i < PART_LAST; i++) - { - /* As a bit of a hack, we want the base image to extend over the text - * and text_aa parts so that we can draw the image either with or without - * the indicator - */ - if (i == PART_BASE) - do_part (pixbuf, PART_BASE, PART_TEXT_AA, PART_TEXT, argv[2], part_names[i]); - else - do_part (pixbuf, i, -1, -1, argv[2], part_names[i]); - } - return 0; -} diff --git a/gtk/theme-bits/radio-13-inconsistent.png b/gtk/theme-bits/radio-13-inconsistent.png deleted file mode 100644 index f8fa57edc7af3b4d8fb0dbba2a1e7f3188f1cbe2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 335 zcmeAS@N?(olHy`uVBq!ia0vp@K+MO%1SG3v8C!uATavfC3&R|SnG922h%WU3if|Tq zL>4nJaPxyOZ8`u6Zlz_~*MO+g~5N(kE?dx!co2QQCi!h~%wn6V&FNUp4h; zP0;&;(+cYs$fs|J@>@C~)+76&Z&$FP%=w(;*r5HVKki@>U|X!e{G09Pik|nfQA#g; z{}uE}GhTA}GnutP#PHf?8HTA>lhi+bN@Og!(;>2Q%{!-M|94nJa0`Gi<67mtr9eUU5>H=O_DdWBVr*tb4A0nsLZ>`k978JR^iH(pYc}9%ov-Y7 zfKwu}`$)r$2uW+jjp0gf_B!php2M(GJmdH#!_8%HSWk(*c%bE_v~|_ggLVI&%%8!q z;h~cLCY$WeFPujU@5!J0(7W#Ybl!RW-CrkfDcpHNwd$_*%6YueRze;fxwH4ig>3pM z5*Eh0z#%Z`jF;}zPbydL`nd(=G0x`uv#ZPYUHjj&JO7(lHTVCE5@ay*2|1=8yh62EttN#X0J5E-AsnztzGCon L^>bP0l+XkKxu$sp -- 2.30.2